package com.ldj.common;

public class CuntomException extends RuntimeException {
    private String errorCode;

    public CuntomException(String customMessage) {
        super(customMessage);
    }

    public CuntomException(String customMessage, String errorCode) {
        super(customMessage);
        this.errorCode = errorCode;
    }

    public CuntomException(String customMessage, String errorCode, Throwable throwable) {
        super(customMessage, throwable);
        this.errorCode = errorCode;
    }

    public String getErrorCode() {
        return this.errorCode;
    }

    public void setErrorCode(String errorCode) {
        this.errorCode = errorCode;
    }

    public String toString() {
        return "CuntomException{, Message='" + this.getMessage() + '\'' + ", errorCode='" + this.errorCode + '\'' + '}';
    }
}
